<%@ page contentType = "text/html;charset=UTF-8" %>
<%@ page language="java" %>
<%@ page import="java.util.*" %>
<%@ page import="com.oval.foundation.parser.ScheduledTaskParser" %>
<% 
   String strIsSubmit=(String)request.getParameter("issubmit");
   String strActionType=(String)request.getParameter("actionType");
   
   
   if(strIsSubmit!=null && strIsSubmit.equalsIgnoreCase("Y"))
   {
      if(strActionType!=null && strActionType.trim().length()>0)
      {
        if("start".equals(strActionType))
        {
           ScheduledTaskParser.restartAllScheduledTask();
        }
        else if("stop".equals(strActionType))
        {
          ScheduledTaskParser.stopAllScheduledTask();
        }
          
      }
      
      
   }
    
%>
<html>
<head>
<title></title>

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link rel="stylesheet" href="css/chinese/csscontent.css" type="text/css">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<form name="cform" method="post" action="ManageScheduledTask.jsp">
<input type="hidden" name="issubmit" value="Y">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td background="images/chinese/title_bg.gif"><img src="images/chinese/title_bg.gif" width="3" height="29"></td>
  </tr>
</table>

<table width="100%" border="0" cellspacing="1" cellpadding="2" bgcolor="#999999">
  <tr> 
    <td colspan="2" class="td_title_bg">
      <img src="images/chinese/arrow2.gif">Scheduled Task Status Manage:</img>
    </td>
  </tr>
  
  
  <tr class="td_bg_row">
    <td class="td_right">Scheduled Task:</td>
    
    <td ><%=System.getProperty("needScheduled")%></td>
  </tr>
  
  
   
   
 <tr class="td_bg1">
    <td class="td_center" colspan="2">
    	<%String s="";
    	if("true".equals(System.getProperty("needScheduled"))){
    	s="Stop All Scheduled Task";
    	%>
        <INPUT TYPE="hidden" name="actionType" value="stop">
      <%}else{
      	s="Start/Restart All Scheduled Task";
      	%>
      	<INPUT TYPE="hidden" name="actionType" value="start">
      <%}%>  
      <INPUT TYPE="submit" name="submit" value="<%=s%>">
    </td> 
 </tr>
</table>

</body>
</html>

